/*
 * 基础功能
 *
 * This is a basic example for apiDoc.
 * Documentation blocks without @api (like this block) will be ignored.
 */

/**
 * @api {post} /admin/base/remoteLogin 远程接口登录
 * @apiName remoteLogin
 * @apiGroup 基础功能
 *
 * @apiParam {String} username 登录用户名.
 * @apiParam {String} password 登录密码.
 *
 * @apiSuccess {String} code 200.
 * @apiSuccess {String} data  数组.
 * @apiSuccess {String} error  空字符.
 *
 * @apiSuccessExample Success-Response:
 *     HTTP/1.1 200 OK
 *      {
 *       "code": "200",
 *       "error": "",
 *       "data": {
	"status": true,
	"user_id": "5eb8c601c33f00002b00547f",
	"users": [{
		"id": "5eb8c601c33f00002b00547f",
		"name": "admin@35.cn",
		"nick_name": "chenzh",
		"account_type": 1,
		"role": "1",
		"status": 1,
		"crm_status": 1,
		"crm_role": "1",
		"company_id": "5eb8c601c33f00002b005480"
	}],
	"companies": [{
		"id": "5eb8c601c33f00002b005480",
		"name": "oobok",
		"max_user_num": 5,
		"user_num": 3,
		"logo": "http:\/\/api.cloud.anymean.com\/static\/images\/common\/default-logo.png",
		"expired_at": "2021\/06\/30",
		"is_expired": false,
		"status": 1,
		"crm_max_user_num": 5,
		"crm_user_num": 1,
		"crm_expired_at": "2020\/07\/04",
		"crm_status": 1
	}]
}
 *     }
 *
 * @apiError 400 具体错误信息.
 *
 * @apiErrorExample Error-Response:
 *     HTTP/1.1 400 Not Found
 *     {
 *       "code": "400",
 *       "error": "UserNotFound",
 *       "data": ""
 *     }
 */

/**
 * @api {post} /admin/base/login 选择企业登录
 * @apiName login
 * @apiGroup 基础功能
 *
 * @apiParam {String} username 登录用户名.
 * @apiParam {String} password 登录密码.
 * @apiParam {String} company_id 公司id remoteLogin中的公司id.
 * @apiParam {String} active_crm 确认激活.
 * @apiParam {String} verifyCode 验证码.
 * @apiParam {String} isRemember 记住密码.
 *
 * @apiSuccess {String} code 200.
 * @apiSuccess {String} data  数组.
 * @apiSuccess {String} error  空字符.
 *
 * @apiSuccessExample Success-Response:
 *     HTTP/1.1 200 OK
 {
	"code": 200,
	"data": {
		"authKey": "0d17e72af2c54862fcb575c20cabcfae",
		"sessionId": "sdslscrmtsdh058uikuirqqb92",
		"userInfo": {
			"id": 1,
			"username": "admin@35.cn",
			"password": "f609bf0c52d2c62356f86f5a63678b8b",
		    ...
		},
		"authList": {
			...
		},
		"menusList": null,
		"loginExpire": 259200
	},
	"error": ""
}
 *
 * @apiError 400 具体错误信息.
 *
 * @apiErrorExample Error-Response:
 *     HTTP/1.1 400 Not Found
 *     {
 *       "code": "400",
 *       "error": "具体错误信息",
 *       "data": ""
 *     }
 */


/**
 * @api {post} /admin/base/register 注册
 * @apiName register
 * @apiGroup 基础功能
 *
 * @apiParam {String} company_name 公司名称.
 * @apiParam {String} name 用户账号.
 * @apiParam {String} nick_name 姓名.
 * @apiParam {String} password 密码.
 * @apiParam {int} account_type 账号类型 1 邮箱 2 手机号.
 * @apiParam {int} vcode 验证码.
 *
 *
 * @apiSuccess {String} code 200.
 * @apiSuccess {String} data  数组.
 * @apiSuccess {String} error  空字符.
 *
 * @apiSuccessExample Success-Response:
 *     HTTP/1.1 200 OK
 {
	"code": 200,
	"data": true,
	"error": ""
}
 *
 * @apiError 400 具体错误信息.
 *
 * @apiErrorExample Error-Response:
 *     HTTP/1.1 400 Not Found
 *     {
 *       "code": "400",
 *       "error": "具体错误信息",
 *       "data": ""
 *     }
 */

/**
 * @api {post} /admin/base/invite 邀请加入短链
 * @apiName invite
 * @apiGroup 基础功能
 *
 * @apiParam {boolean} open_yun 是否加入云门户.
 * @apiParam {String} structure_remote_id 部门remote_id.
 *
 *
 * @apiSuccess {String} code 200.
 * @apiSuccess {String} data  数组.
 * @apiSuccess {String} error  空字符.
 *
 * @apiSuccessExample Success-Response:
 *     HTTP/1.1 200 OK
 {
	"code": 200,
	"data": {
		"qrcode": "",
		"url": "https://api.cloud.35.cn/s/oIkb44t"
	},
	"error": ""
}
 *
 * @apiError 400 具体错误信息.
 *
 * @apiErrorExample Error-Response:
 *     HTTP/1.1 400 Not Found
 *     {
 *       "code": "400",
 *       "error": "具体错误信息",
 *       "data": ""
 *     }
 */

/**
 * @api {post} /admin/base/isExisted 用户名是否存在
 * @apiName isExisted
 * @apiGroup 基础功能
 *
 * @apiParam {String} name 用户名.
 *
 *
 * @apiSuccess {String} code 200.
 * @apiSuccess {String} data  数组.
 * @apiSuccess {String} error  空字符.
 *
 * @apiSuccessExample Success-Response:
 *     HTTP/1.1 200 OK
 {
	"code": 200,
	"data": {
		"is_existed": "true"
	},
	"error": ""
}
 *
 * @apiError 400 具体错误信息.
 *
 * @apiErrorExample Error-Response:
 *     HTTP/1.1 400 Not Found
 *     {
 *       "code": "400",
 *       "error": "具体错误信息",
 *       "data": ""
 *     }
 */

/**
 * @api {post} /admin/base/registerByInvite 邀请加入公司(注册)
 * @apiName registerByInvite
 * @apiGroup 基础功能
 *
 * @apiParam {String} invite_id 邀请id.
 * @apiParam {String} name 账号.
 * @apiParam {String} nick_name 姓名.
 * @apiParam {String} password 密码.
 * @apiParam {String} account_type 账号类型.
 *
 * @apiSuccess {String} code 200.
 * @apiSuccess {String} data  数组.
 * @apiSuccess {String} error  空字符.
 *
 * @apiSuccessExample Success-Response:
 *     HTTP/1.1 200 OK
 {
	"code": 200,
	"data": true,
	"error": ""
}
 *
 * @apiError 400 具体错误信息.
 *
 * @apiErrorExample Error-Response:
 *     HTTP/1.1 400 Not Found
 *     {
 *       "code": "400",
 *       "error": "具体错误信息",
 *       "data": ""
 *     }
 */

/**
 * @api {post} /admin/base/joinByInvite 邀请加入公司(加入)
 * @apiName joinByInvite
 * @apiGroup 基础功能
 *
 * @apiParam {String} invite_id 邀请id.
 * @apiParam {String} name 账号.
 * @apiParam {String} nick_name 姓名.
 * @apiParam {String} password 密码.
 *
 * @apiSuccess {String} code 200.
 * @apiSuccess {String} data  数组.
 * @apiSuccess {String} error  空字符.
 *
 * @apiSuccessExample Success-Response:
 *     HTTP/1.1 200 OK
 {
	"code": 200,
	"data": true,
	"error": ""
}
 *
 * @apiError 400 具体错误信息.
 *
 * @apiErrorExample Error-Response:
 *     HTTP/1.1 400 Not Found
 *     {
 *       "code": "400",
 *       "error": "具体错误信息",
 *       "data": ""
 *     }
 */

/**
 * @api {post} /admin/base/applyExtension 试用版延长
 * @apiName applyExtension
 * @apiGroup 基础功能
 *
 * @apiParam {String} null 无需参数.
 *
 * @apiSuccess {String} code 200.
 * @apiSuccess {String} data  数组.
 * @apiSuccess {String} error  空字符.
 *
 * @apiSuccessExample Success-Response:
 *     HTTP/1.1 200 OK
 {
	"code": 200,
	"data": true,
	"error": ""
}
 *
 * @apiError 400 具体错误信息.
 *
 * @apiErrorExample Error-Response:
 *     HTTP/1.1 400 Not Found
 *     {
 *       "code": "400",
 *       "error": "具体错误信息",
 *       "data": ""
 *     }
 */

/**
 * @api {post} /admin/base/sendVcode 短信邮箱验证码
 * @apiName sendVcode
 * @apiGroup 基础功能
 *
 * @apiParam {String} account 账号.
 * @apiParam {String} account_type 账号类型.
 * @apiParam {String} key 场景 register .
 *
 * @apiSuccess {String} code 200.
 * @apiSuccess {String} data  数组.
 * @apiSuccess {String} error  空字符.
 *
 * @apiSuccessExample Success-Response:
 *     HTTP/1.1 200 OK
 {
	"code": 200,
	"data": true,
	"error": ""
}
 *
 * @apiError 400 具体错误信息.
 *
 * @apiErrorExample Error-Response:
 *     HTTP/1.1 400 Not Found
 *     {
 *       "code": "400",
 *       "error": "具体错误信息",
 *       "data": ""
 *     }
 */

/**
 * @api {get} /admin/base/getVerify 图形验证码
 * @apiName getVerify
 * @apiGroup 基础功能
 *
 * @apiParam {String} null 无参数.
 *
 * @apiSuccess {String} code 200.
 * @apiSuccess {String} data  数组.
 * @apiSuccess {String} error  空字符.
 *
 * @apiSuccessExample Success-Response:
 *     HTTP/1.1 200 OK
 	返回图片资源
 *
 * @apiError 400 具体错误信息.
 *
 * @apiErrorExample Error-Response:
 *     HTTP/1.1 400 Not Found
 *     {
 *       "code": "400",
 *       "error": "具体错误信息",
 *       "data": ""
 *     }
 */